// 1:待标注 2:待初审 3:初审驳回 4:待复审 5:复审驳回 6:复审通过 7:已关闭
// 审批状态
export type AnnotationStatus = 1 | 2 | 3 | 4 | 5 | 6 | 7;
// enum
export enum JobStatusEnum {
    WAITING_ANNOTATION = 1,
    WAITING_FIRST_REVIEW = 2,
    FIRST_REVIEW_REJECTED = 3,
    WAITING_SECOND_REVIEW = 4,
    SECOND_REVIEW_REJECTED = 5,
    SECOND_REVIEW_APPROVED = 6,
    CLOSED = 7,
}

export interface ApprovalData {
    /**
     * 审核原因 通过不填，驳回必填
     */
    remark?: string;
    /**
     * 子任务ID
     */
    subTaskId: number | string;
    /**
     * 1:待标注 2:待初审 3:初审驳回 4:待复审 5:复审驳回 6:复审通过 7:已关闭
     */
    subTaskStatus: AnnotationStatus;
}

/**
 * 任务和图片信息
 */
export interface TaskImageInfo {
    /**
     * 任务审核记录
     */
    auditRecord: AuditRecord;
    /**
     * sub TaskId
     */
    id: number;
    subTaskImage: SubTaskImage[];
    subTaskStatus: AnnotationStatus;
    [property: string]: any;
}

/**
 * 任务审核记录
 */
export interface AuditRecord {
    /**
     * 审核记录ID 编号
     */
    id: number;
    /**
     * 审核记录时间
     */
    operateTime: string;
    /**
     * 审核原因
     */
    remark: string;
    /**
     * 子任务Id
     */
    subTaskId: number;
    [property: string]: any;
}

export interface SubTaskImage {
    /**
     * subTaskImage Id
     */
    id: number;
    /**
     * 图片ID
     */
    imageId: number;
    /**
     * 图片文件名
     */
    imageName: string;
    /**
     * 子任务ID
     */
    subTaskId: number;
    /**
     * 图片中间状态
     */
    temStatus: 0 | 1;
    [property: string]: any;
}

export interface ReviewAnnotationData {
    /**
     * 审核人Id
     */
    auditorId: number;
    /**
     * cvat任务id
     */
    cvatTaskId: string;
    /**
     * jobID
     */
    jobId: number;
    /**
     * 复审人ID
     */
    reAuditorId: number;
    res: any[];
    /**
     * 子任务ID
     */
    subTaskId: number;
}
